/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package encrypt;

/**
 *
 * @author XuanHung
 */
public class NullCipher implements BlockCipher
{
        private int blockSize = 8;
       
        public NullCipher()
        {
        }

        public NullCipher(int blockSize)
        {
                this.blockSize = blockSize;
        }
       
        @Override
        public void init(boolean forEncryption, byte[] key)
        {
        }

        @Override
        public int getBlockSize()
        {
                return blockSize;
        }

        @Override
        public void transformBlock(byte[] src, int srcoff, byte[] dst, int dstoff)
        {
                System.arraycopy(src, srcoff, dst, dstoff, blockSize);
        }
}

